/*
 * sdlwindow.h
 *
 *  Created on: 30.06.2011
 *      Author: marcell
 */

#ifndef __SDLWINDOW_H__
#define __SDLWINDOW_H__


#include <iwindow.h>
#include <SDL.h>

/**
 * \addtogroup engine
 * @{
 */
/**
 * @brief SDL implementation of the iWindow interface
 */
class ceSDLWindow : public iWindow
{
  CE_OBJECT;
private:
  SDL_Surface*  surface;
  ceWindowHandle windowHandle;

public:
  ceSDLWindow ();
  virtual ~ceSDLWindow ();

  bool createWindow (unsigned width,
                     unsigned height,
                     unsigned depth,
                     bool     fullscreen,
                     unsigned rColor = 8,
                     unsigned gColor = 8,
                     unsigned bColor = 8,
                     unsigned aColor = 8,
                     unsigned doubleBuffer = 1,
                     unsigned depthSize = 24,
                     unsigned stencilSize = 8);

  int GetX () const;
  int GetY () const;
  unsigned GetWidth () const;
  unsigned GetHeight () const;
  bool IsFullscreen () const;
  ceWindowHandle GetWindowHandle ();
};

/** @} */

#endif /* ! __SDLWINDOW_H__ */
